package com.dongjiantong.common.utils;

import java.security.SecureRandom;
import java.util.UUID;

/**
 * Created by cao on 2017/10/27.
 */
public class UUIDUtil {

    /**
     * UUID
     * @return
     */
    public static String UUID() {
        String uuid = UUID.randomUUID().toString();
        return uuid.replaceAll("-", "");
    }

    /**
     * 随机生成全局维一Id
     * @return
     */
    public static Long getGId()
    {
        IdWorker id = new IdWorker();
        return id.nextId();
    }

}
